package com.xplay.xpocker.room;

import com.xplay.xpocker.dvo.RoomInfoInterface;
import com.xplay.xpocker.dvo.RoomRuleInterface;
import com.xplay.xpocker.dvo.AbstractRoom;
import lombok.Data;

import java.util.LinkedList;

@Data
public class RoomThreadContent<T extends RoomRuleInterface, R extends RoomInfoInterface,L> {
    public AbstractRoom<T, R,L> roomInfo;
    private LinkedList<Message> messageList;

    public RoomThreadContent() {
    }

    public RoomThreadContent(AbstractRoom<T, R,L> roomInfo, LinkedList<Message> messageList) {
        this.roomInfo = roomInfo;
        this.messageList = messageList;
    }

    public RoomThreadContent(AbstractRoom<T, R,L> roomInfo) {
        this.roomInfo = roomInfo;
        this.messageList = new LinkedList<>();
    }

    public void addMessage(Message message) {
        this.messageList.add(message);
    }
}
